//
//  XSTestModel.h
//  XSDataBaseDemo
//
//  Created by 大帅 on 2023/12/19.
//

#import <Foundation/Foundation.h>

#import "XSEnumHeader.h"   // 枚举头文件
#import <SJMediaCacheServer/SJMediaCacheServer.h>   // 缓存

NS_ASSUME_NONNULL_BEGIN

@interface XSTestModel : NSObject
/// 视频播放地址
@property (nonatomic, strong) NSString *url;
/// 视频id
@property (nonatomic, strong) NSString *videoId;
/// 视频名称
@property (nonatomic, strong) NSString *videoName;
/// 下载状态
@property (nonatomic, assign) XSDownloadStatus state;
/// Mp4视频下载完成地址
@property (nonatomic, strong) NSString *localUrl;
/// M3u8视频下载完成地址
@property (nonatomic, strong) NSString *locaM3u8lUrl;
/// 视频下载完成存储的文件夹地址（全部删除时直接删除文件夹即可）
@property (nonatomic, strong) NSString *localFolder;
/// 视频下载的数据
@property (nonatomic, strong) NSData *resumeData;
/// 视频已下载大小
@property (nonatomic, assign) NSUInteger downloadSize;
/// 视频总大小
@property (nonatomic, assign) NSUInteger totalSize;
/// 视频已下载大小（M3u8）
@property (nonatomic, assign) NSInteger downloadSizeM3u8;
/// 视频总大小（M3u8）
@property (nonatomic, assign) NSUInteger totalSizeM3u8;
/// 上次计算速度时的时间戳
@property (nonatomic, assign) NSTimeInterval lastSpeedTime;
/// 计算速度时间内下载文件的大小
@property (nonatomic, assign) NSUInteger intervalSize;
/// 下载速度
@property (nonatomic, assign) NSUInteger speed;
/// 下载进度
@property (nonatomic, assign) CGFloat progress;


@end

NS_ASSUME_NONNULL_END
